<?PHP

require_once WACT_ROOT . 'db/db.inc.php';


class Price {
	function Price() {
	}

	function  &getPriceByType($type) {
        return DBC::FindRecord("SELECT P.* FROM sport_prices P
        WHERE P.type = ". DBC::makeLiteral($type));
    }

    function  &getPrice($type) {
    	$rs =& Price::getPriceByType($type);
    	if ($rs) return $rs->get('price');
    	else return 0;
    }
}
?>
